//package testElasticsearch;
//
//import org.elasticsearch.client.Client;
//import org.elasticsearch.client.transport.TransportClient;
//import org.elasticsearch.common.settings.ImmutableSettings;
//import org.elasticsearch.common.settings.Settings;
//import org.elasticsearch.common.transport.InetSocketTransportAddress;
//
//public class ElasticsearchUtil {
//	private TransportClient client;
//	//连接操作
//	public TransportClient getClient(){
//		Settings settings = ImmutableSettings.settingsBuilder().put("cluster.name", "lpdb_test").build();
//		client = new TransportClient(settings);
//		client.addTransportAddress(new InetSocketTransportAddress("192.168.3.81",9301));
//		return client;
//	}
//	//关闭操作
//	public void closeClient(){
//		client.close();
//	}
//	
//}
